<%@page import="java.sql.*,online.*,java.util.*,java.lang.*"%>
<html>

<head>
	<title>Header</title>	
    <style type="text/css">
     A:link 
	 {
     	text-decoration: none;
     	color:yellow;
     	font-family: verdana;
     	
		font-size: 9pt;
     }
     A:visited 
	 {
     	text-decoration:none;
     	font-family: verdana;
     	color: yellow;
     	
        font-size: 9pt;
     }
     A:hover 
	 {
     	text-decoration:none;
     	color: pink;
     	font-family: verdana;

        font-size: 9pt;
     }
</style>

    <meta name="Microsoft Theme" content="strtedge 001">

</head>
<body topmargin=0 leftmargin=0 background="strbkgde.gif" bgcolor="#FFFFFF" text="#000000" link="#660000" vlink="#003399" alink="#999933">
<!--mstheme--><font face="Arial, Helvetica">
<img border="0" src="Onlineedu5.jpg" width="789" height="61">
<!--mstheme--></font>
<TABLE bgcolor="#006699" border=0  width=790>
<tr align="right" align="center">	
	<td align="center" width="782" valign="center">
    <!--mstheme--><font face="Arial, Helvetica">
    <font color="#FFFFA4" align="center">
<b>EXamination Time Table</b>&nbsp;&nbsp;<b> 
	</font>
 
    <!--mstheme--></font>
 
	</td>
	  <td width="6%" nowrap bordercolor="#006699" bgcolor="#006699" height="1"><!--mstheme--><font face="Arial, Helvetica"><div align="right"><strong><a href="AboutUs.htm"><font color="#FFFFA4">Home</font></a><font color="#FFFFA4">|
          </font></strong><font size="1" color="#FFFFA4"><b><a href="student.htm">Back</a></b></font></div><!--mstheme--></font></td>
</tr>
</table>
<!--mstheme--><font face="Arial, Helvetica"><!--mstheme--></font>

		<p><br>
		<table width="100%" border="0">
		<tr bordercolor="#996600"> 
            <td colspan="3" bgcolor="#996600"><div align="center"><font color="#FFFFFF"><strong>Exam Time Table</strong></font></div></td>
          </tr>
          <tr bordercolor="#996600" bgcolor="#996600"> 
            <td colspan="3"><div align="center"><strong><font color="#FFFFFF">
			<%
					Class.forName("oracle.jdbc.driver.OracleDriver");
					Connection con=DriverManager.getConnection("jdbc:oracle:thin:@server:1521:server","edu","edu");
					Statement st=con.createStatement();
					String ssss="select course_id from student_course_master where student_id='"+session.getAttribute("StudentId")+"'";
					System.out.println(ssss);
					ResultSet rs=st.executeQuery(ssss);
					if(rs.next())
					{
						ResultSet rs1=st.executeQuery("select course_name  from course_master where course_id='"+rs.getString(1)+"'");
						if(rs1.next())%>
							<%=rs1.getString(1)%>
							<%
					}
			%>
			</font></strong></div></td>
          </tr>
          <tr bordercolor="#996600" bgcolor="#996600"> 
            <td><div align="center"><strong><font color="#FFFFFF">Date</font></strong></div></td>
            <td><div align="center"><font color="#FFFFFF"><strong>Time</strong></font></div></td>
            <td><div align="center"><strong><font color="#FFFFFF">Subject</font></strong></div></td>
          </tr>
	<%
			Class.forName("oracle.jdbc.driver.OracleDriver");
			 con=DriverManager.getConnection("jdbc:oracle:thin:@server:1521:server","edu","edu");
			Statement st1=con.createStatement();
			ResultSet rs1=st1.executeQuery("select * from EXAM_TIMETABLE_MASTER");		
			
			while(rs1.next())
			{
				System.out.println(rs1.getString(2));
	%>
        
          
          <tr bordercolor="#ffddbb" bgcolor="#ffddbb"> 
            <td><%=rs1.getDate(3)%></td>
            <td><%=rs1.getString(4)%></td>
            <td>
			  <%
					Statement st2=con.createStatement();
					String sss="select subject_name from subject_master where subject_id='"+rs1.getString(2)+"'";
					ResultSet rs2=st2.executeQuery(sss); 
					rs2.next();
			  %><%=rs2.getString(1)%></td>
          </tr>
	<%
			}
   %>
        </table>
	</body><%con.close();%>
</html>